<!DOCTYPE html>
<html>
<head>
<title>版本控制</title>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta
	content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
	name="viewport">
<link rel="stylesheet" href="../../css/flowdesigner.css">	
<link rel="stylesheet" href="../../css/bootstrap.min.css">
<link rel="stylesheet" href="../../css/font-awesome.min.css">
<link rel="stylesheet"
	href="../../plugins/jqgrid/ui.jqgrid-bootstrap.css">
<link rel="stylesheet"
	href="../../plugins/ztree/css/metroStyle/metroStyle.css">
<link rel="stylesheet" href="../../css/main.css">
<script src="../../libs/jquery.min.js"></script>
<script src="../../plugins/layer/layer.js"></script>
<script src="../../libs/bootstrap.min.js"></script>
<script src="../../libs/vue.min.js"></script>
<script src="../../plugins/jqgrid/grid.locale-cn.js"></script>
<script src="../../plugins/jqgrid/jquery.jqGrid.min.js"></script>
<script src="../../js/common.js"></script>
<script src="../../libs/ajaxupload.js"></script>
<style type="text/css">
.overdiv{position:fixed; z-index:9997;top:0;left:0;width:100%; height:100%;background-color:white;filter: alpha(opacity=50); opacity: 0.5;text-align: center;color: white;}
.overdiv1{top:50%;margin-left:-32px;margin-top:-32px;left:50%;position:fixed; z-index:9999;overflow:auto;}
</style>
</head>
<body>
	<div id="down_div" class="overdiv xhide"></div>
    <div id="over_div" class="overdiv1 xhide"><img src="../../images/syspic/wait.gif" alt="txby" /></div>
	<div id="rrapp" v-cloak>
		<div v-show="showList">
			<div class="grid-btn">
				<div class="form-group col-sm-2">
					<input type="text" class="form-control" v-model="q.appName"
						@keyup.enter="query" placeholder="应用名称">
				</div>
			<!-- 	<a class="btn btn-primary" id="upload"><i class="fa fa-plus"></i>&nbsp;上传文件</a> -->
				<a class="btn btn-default" @click="query">查询</a> <a
					v-if="hasPermission('pro:sysversion:save')" class="btn btn-primary"
					@click="add"><i class="fa fa-plus"></i>&nbsp;新增</a> <a
					v-if="hasPermission('pro:sysversion:update')"
					class="btn btn-primary" @click="update"><i
					class="fa fa-pencil-square-o"></i>&nbsp;修改</a> <a
					v-if="hasPermission('pro:sysversion:delete')"
					class="btn btn-primary" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
					<a   class="btn btn-primary" @click="downloadData('pro/download')"><i class="fa fa-download"></i>&nbsp;下载</a>
			</div>
			<table id="jqGrid"></table>
			<!-- 分页 -->
			<div id="jqGridPager"></div>
		</div>
		<!-- 新增 -->
		<div v-show="!showList" class="panel panel-default">
			<div class="panel-heading">{{title}}</div>
			<form class="form-horizontal">
				<div class="form-group">
					<div class="col-sm-2 control-label">应用名称<span  style="color: red;font-size: 16px">*</span></div>
					<div class="col-sm-10">
						<input type="text" class="form-control"
							v-model="sysversion.appName" placeholder="应用名称" />
					</div>
				</div>
			<!-- 	<div class="form-group">
					<div class="col-sm-2 control-label">类型</div>
					<div class="col-sm-10">
						<select v-model="sysversion.flag" class="form-control" @change="queryVersion">
						  <option value ="0">demo版本</option>
						  <option value ="1">release版本</option>
						</select>
					</div>
				</div> -->
					<div class="form-group">
					<div class="col-sm-2 control-label">类型<span  style="color: red;font-size: 16px">*</span></div>
					<div class="col-sm-10">
						<select v-model="sysversion.flag" class="form-control" >
						  <option value ="0">demo版本</option>
						  <option value ="1">release版本</option>
						</select>
					</div>
				</div>
				<div class="form-group">
					<div class="col-sm-2 control-label" >程序类型<span  style="color: red;font-size: 16px">*</span></div>
					<div class="col-sm-10">
						  <select v-model="sysversion.pType" class="form-control" >
						  <option value ="0">sick</option>
						  <option value ="1">nurse</option>
						</select>
					</div>
				</div>

				<div class="form-group">
					<div class="col-sm-2 control-label" >URL<span  style="color: red;font-size: 16px">*</span></div>
					<div class="col-sm-10">
						<input type="text" class="form-control"
							v-model="sysversion.downloadUrl" placeholder="URL" id="upload" readonly="readonly"/>
							<!-- <a class="btn btn-primary" id="upload"><i class="fa fa-plus"></i>&nbsp;上传文件</a> -->
					</div>
				</div>
				
				<div class="form-group">
					<div class="col-sm-2 control-label">版本号<span  style="color: red;font-size: 16px">*</span></div>
					<div class="col-sm-10">
						<input type="text" class="form-control"
							v-model="sysversion.versionName" placeholder="版本号  如1.0.0" onblur="check()" id="versionName"/>
					</div>
				</div>
				<div class="form-group">
					<div class="col-sm-2 control-label">版本标识<span  style="color: red;font-size: 16px">*</span></div>
					<div class="col-sm-10">
						<input type="number" class="form-control"
							v-model="sysversion.versionCode" placeholder="版本标识"  />
					</div>
				</div>
				<!-- <div class="form-group">
					<div class="col-sm-2 control-label">版本标识</div>
					<div class="col-sm-10">
						<input type="number" class="form-control"
							v-model="sysversion.versionCode" placeholder="版本标识" id="versionCode" readonly="readonly"/>
					</div>
				</div> -->
				<div class="form-group">
					<div class="col-sm-2 control-label">备注</div>
					<div class="col-sm-10">
						<textarea  class="form-control"
							v-model="sysversion.content" placeholder="备注" />
						</textarea> 
					</div>
				</div>
				
				<!-- <div class="form-group">
					<div class="col-sm-2 control-label">操作时间</div>
					<div class="col-sm-10">
						<input type="text" class="form-control" onfocus="WdatePicker({skin:'twoer',dateFmt:'yyyy-MM-dd HH:mm:ss'})"
							v-model="sysversion.time" placeholder="操作时间" id="time"/>
					</div>
				</div> -->
				<div class="form-group">
					<div class="col-sm-2 control-label"></div>
					<input type="button" class="btn btn-primary" @click="saveOrUpdate"
						value="确定"  id="sub"/> &nbsp;&nbsp;<input type="button"
						class="btn btn-warning" @click="reload" value="返回" />
				</div>
			</form>
		</div>
	</div>
	<script src="../../js/modules/pro/sysversion.js"></script>
	<script language="javascript" type="text/javascript" src="../../js/modules/WdatePicker.js"></script>
</body>
</html>